import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Scanner;
import java.util.StringTokenizer;

class Read {
    StringTokenizer st=new StringTokenizer("");
    BufferedReader bf=new BufferedReader(new InputStreamReader(System.in));
    public String next() throws IOException {
        while (!st.hasMoreTokens()){
            st=new StringTokenizer(bf.readLine());
        }
        return st.nextToken();
    }
    public String nextLine() throws IOException {
        return bf.readLine();
    }
    public int nextInt() throws IOException {
        return Integer.parseInt(next());
    }
}
public class Main {
    public static void main1(String[] args) {
        Scanner in=new Scanner(System.in);
        int n= in.nextInt();
        int[][] nums=new int[n][2];
        for (int i = 0; i < n; i++) {
            nums[i][0]=in.nextInt();
            nums[i][1]= in.nextInt();
        }
        int[] dp=new int[n];
        dp[0]=1;
        for (int i = 1; i < n; i++) {
            dp[i]=1;
            for (int j = 0; j < i; j++) {
                if(nums[i][0]>=nums[j][1]){
                    dp[i]=Math.max(dp[i],dp[j]+1);
                }
            }
        }
        System.out.println(dp[n-1]);
    }
    public static void main2(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int[][] nums = new int[n][2];
        for (int i = 0; i < n; i++) {
            nums[i][0] = in.nextInt();
            nums[i][1] = in.nextInt();
        }
        Arrays.sort(nums,(a, b)->{
            return a[0]<=b[0]?-1:1;
        });
        int ret=1,r=nums[0][1];
        for (int i = 1; i < n; i++) {
            if(r>nums[i][0]) {
                r=Math.min(r,nums[i][1]);
            }
            else {
                ret++;
                r=nums[i][1];
            }
        }
        System.out.println(ret);
    }

    public static void main3(String[] args) {
        Scanner in=new Scanner(System.in);
        int n= in.nextInt(),k=in.nextInt(),d=in.nextInt();
        Integer[] nums=new Integer[n];
        for (int i = 0; i < n; i++) {
            nums[i]= in.nextInt();
        }
        Arrays.sort(nums,(a,b)->{
            return b - a;
        });
        int ret=1,pos=0;
        for (int i = 0; i < n; i++) {
            if(nums[i]-nums[i+k-1]<=d) {
                pos=i;
                break;
            }
        }
        int i=0;
        while (i++<k){
            ret*=nums[pos++];
        }
        System.out.println(ret);
    }

    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int n= in.nextInt(),k= in.nextInt(),d= in.nextInt();
    }
}